/*
 * To change this template, choose Tools | Templates and open the template in
 * the editor.
 */
package parser.part.n3;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

/**
 *
 * @author Patronus
 */
public class Creator {

    ArrayList<ConditionContainer> list;
    HashMap<String, Integer> containerPositions = new HashMap<String, Integer>();
    /*зачем  ?
     * ведь когда использую 
     */

    /**
     * 
     * @param parent
     * @param condition
     */
    public void addContainer(String parent, boolean condition) {
    }
    //adding new elements

    private void extendTree(int maxCount) {
        while (list.size() - 1 < maxCount) {
            list.add(null);
        }
    }

    private int getNextChild(int parentPosition, boolean conditionResult) {
        return (conditionResult) ? parentPosition * 2 : parentPosition * 2 + 1;

    }

    private void fillConteinerPositionung(List tree) {
        for (Object element : tree) {
            ConditionContainer conteiner = (ConditionContainer) element;
        }
    }
}
